package com.sen.ssp.sys.config.action;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

import com.sen.ssp.sys.config.entity.ConfigInfo;
import com.sen.ssp.sys.config.services.ConfigInfoService;

/**
 * 配置类别管理控制器
 * 
 * @author sen
 * 
 */
@Controller
@RequestMapping("/ssp/sys/config")
public class ConfigInfoController {
	
	@Autowired
	private ConfigInfoService configInfoService;
	
	@RequestMapping(value="view", method=RequestMethod.GET)
	public void view(Model model) {
		model.addAttribute("foo", "foo value");
		model.addAttribute("tee", "tee value");
		Map<String, Object> params = new HashMap<String, Object>();
		params.put("skip", 0);
		params.put("max", 5);
		List<ConfigInfo> retData = configInfoService.queryConfigInfo(params, 0, 5);
		System.out.println(retData);
	}
}
